import 'package:flutter/material.dart';
import 'package:zhongyiapp/pages/consilia.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Examplescreen(),
    );
  }
}

class Examplescreen extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: Stack(
        children: [
          Image.asset(
            'assets/背景图1.png', // 替换为你的图片路径
            fit: BoxFit.cover,
            width: double.infinity,
            height: double.infinity,
          ),
          Column(
            children: const [
              bar(),
              body1(),
              SizedBox(
                height: 10.0,
              ),
              body2()
            ],
          ),
        ],
      ),
    );
  }
}

class bar extends StatelessWidget {
  const bar({Key? key}) : super(key: key);
  @override
  Widget build(BuildContext context) {
    return Container(
        padding: EdgeInsets.only(top: 10.0),
        width: 420,
        height: 70,
        child: Column(children: <Widget>[
          ListTile(
            leading: GestureDetector(
              onTap: () {
                // 处理点击事件，跳转到其他页面
                Navigator.push(context,
                    MaterialPageRoute(builder: (context) => Consiliascreen()));
              },
              child: Icon(
                Icons.arrow_back_ios,
                size: 20.0,
                color: Colors.black,
              ),
            ),
            title: Text(
              '桂枝汤治疗颈椎病',
              textAlign: TextAlign.center,
              style: TextStyle(
                  fontSize: 20.0, color: Colors.black, fontFamily: '行楷'),
            ),
          ),
        ]));
  }
}

class body1 extends StatelessWidget {
  const body1({Key? key}) : super(key: key);
  @override
  Widget build(BuildContext context) {
    return Container(
      width: 380,
      height: 190,
      decoration: BoxDecoration(
          color: Color.fromARGB(128, 255, 255, 255),
          borderRadius: BorderRadius.circular(16.0)),
      child: Column(children: <Widget>[
        SizedBox(
          height: 10.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 5.0,
            ),
            Text(
              '桂枝汤治疗颈椎病',
              style: TextStyle(
                  fontSize: 26,
                  fontFamily: '行楷',
                  color: Color.fromARGB(249, 52, 51, 51)),
            ),
          ],
        ),
        SizedBox(
          height: 10.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
              height: 10.0,
            ),
            Text(
              '医家:',
              style: TextStyle(
                  fontSize: 20, color: Color.fromARGB(255, 130, 96, 58)),
            ),
            Text(
              '胡希怒',
              style: TextStyle(color: Colors.grey, fontSize: 18.0),
            )
          ],
        ),
        SizedBox(
          height: 10.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
            ),
            Text(
              '症状:',
              style: TextStyle(
                  fontSize: 20, color: Color.fromARGB(255, 130, 96, 58)),
            ),
            Text(
              '手臂麻木、肩痛、手颤抖、上肢无力',
              style: TextStyle(color: Colors.grey, fontSize: 18.0),
              softWrap: true,
            ),
          ],
        ),
        SizedBox(
          height: 10.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
            ),
            Text(
              '提要:',
              style: TextStyle(
                  fontSize: 20, color: Color.fromARGB(255, 130, 96, 58)),
            ),
            Text(
              '两肩疼，颈椎骨质增生',
              style: TextStyle(color: Colors.grey, fontSize: 18.0),
              softWrap: true,
            ),
          ],
        ),
      ]),
    );
  }
}

class body2 extends StatelessWidget {
  const body2({Key? key}) : super(key: key);
  @override
  Widget build(BuildContext context) {
    return Container(
      width: 380,
      height: 600,
      decoration: BoxDecoration(
          color: Color.fromARGB(128, 255, 255, 255),
          borderRadius: BorderRadius.circular(16.0)),
      child: Column(children: <Widget>[
        SizedBox(
          height: 10.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 5.0,
            ),
            Icon(
              Icons.account_circle,
              color: Color.fromARGB(255, 130, 96, 58),
              size: 30.0,
            ),
            SizedBox(
              width: 3.0,
            ),
            Text(
              '诊断',
              style: TextStyle(fontSize: 26, fontFamily: '行楷'),
            ),
          ],
        ),
        SizedBox(
          height: 7.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
              height: 7.0,
            ),
            Text(
              '患者:',
              style: TextStyle(
                  fontSize: 20, color: Color.fromARGB(255, 130, 96, 58)),
            ),
            Text(
              '王某，48岁',
              style: TextStyle(color: Colors.grey, fontSize: 18.0),
            )
          ],
        ),
        SizedBox(
          height: 7.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
            ),
            Text(
              '初诊:',
              style: TextStyle(
                  fontSize: 20, color: Color.fromARGB(255, 130, 96, 58)),
            )
          ],
        ),
        SizedBox(
          height: 5.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
            ),
            Expanded(
              child: Text(
                '两肩疼，曾经针灸、拔罐、烤电等均无效。于1965年6月在中国人民解放军海军总医院确诊为颈椎第六节骨质增生。现两臂麻木、疼，右手颤不能写字，肢软无力，头不能后仰，右手指知觉迟钝。脉沉细，苔白。',
                style: TextStyle(fontSize: 18.0, color: Colors.grey),
              ),
            )
          ],
        ),
        SizedBox(
          height: 7.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
            ),
            Text(
              '初诊处方:',
              style: TextStyle(
                  fontSize: 20, color: Color.fromARGB(255, 130, 96, 58)),
            )
          ],
        ),
        SizedBox(
          height: 5.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
            ),
            Expanded(
              child: Text(
                '桂枝加茯苓白术附子汤，与下方：桂枝三钱，白芍三钱，生姜三钱，大枣三枚，苍术三钱，茯苓四钱，附子二钱，炙甘草二钱。',
                style: TextStyle(fontSize: 18.0, color: Colors.grey),
              ),
            )
          ],
        ),
        SizedBox(
          height: 7.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
            ),
            Text(
              '二诊:',
              style: TextStyle(
                  fontSize: 20, color: Color.fromARGB(255, 130, 96, 58)),
            )
          ],
        ),
        SizedBox(
          height: 5.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
            ),
            Expanded(
              child: Text(
                '服上方六剂。白天微觉轻松。',
                style: TextStyle(fontSize: 18.0, color: Colors.grey),
              ),
            )
          ],
        ),
        SizedBox(
          height: 7.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
            ),
            Text(
              '二诊处方:',
              style: TextStyle(
                  fontSize: 20, color: Color.fromARGB(255, 130, 96, 58)),
            )
          ],
        ),
        SizedBox(
          height: 5.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
            ),
            Expanded(
              child: Text(
                '原方增附子为三钱。',
                style: TextStyle(fontSize: 18.0, color: Colors.grey),
              ),
            )
          ],
        ),
        SizedBox(
          height: 7.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
            ),
            Text(
              '三诊:',
              style: TextStyle(
                  fontSize: 20, color: Color.fromARGB(255, 130, 96, 58)),
            )
          ],
        ),
        SizedBox(
          height: 5.0,
        ),
        Row(
          children: <Widget>[
            SizedBox(
              width: 8.0,
            ),
            Expanded(
              child: Text(
                '臂疼已，头可后仰，但两臂麻木未除。',
                style: TextStyle(fontSize: 18.0, color: Colors.grey),
              ),
            )
          ],
        ),
      ]),
    );
  }
}
